home *** CD-ROM | disk | FTP | other *** search
/ Almathera Ten Pack 3: CDPD 3 / Almathera Ten on Ten - Disc 3: CDPD3.iso / ab20 / ab20_archive / languages / assembly / powervisor_113.lzh / docs / Screen < prev    next >
Text File  |  1992-02-06  |  42KB  |  1,067 lines

  1. *-------------------*
  2. * Tutorial : screen * Thu Feb  6 16:13:22 1992
  3. *-------------------*
  4.  
  5. ===================== Commands used in this tutorial =========================
  6.  
  7.    active      Set active logical window
  8.    awin        Open the 'Rexx' logical window
  9.    color       Set RGB colors for PowerVisor screen
  10.    colrow      Set the number of columns and rows for a logical window
  11.    current     Make another logical window the current one
  12.    dwin        Open the 'Debug' logical window
  13.    fit         Fit the logical window to the visible size
  14.    home        Go to the home position of the logical window
  15.    list        Show a list (tasks, libraries, message ports, ...)
  16.    log         Log output to a file
  17.    memory      List memory
  18.    mode        Set PowerVisor preferences
  19.    move        Move a physical window
  20.    on          Execute command on other logical window
  21.    owin        Open the 'PPrint' logical window
  22.    prefs       Set preferences
  23.    refresh     Refresh a command on the 'Refresh' logical window
  24.    rwin        Open the 'Refresh' logical window
  25.    screen      Set PowerVisor on another screen
  26.    setfont     Set another font on a logical window
  27.    size        Size a physical window
  28.    swin        Open the 'Source' logical window
  29.    to          Redirect output to a file
  30.    xwin        Open the 'Extra' logical window
  31.  
  32.  
  33. ===================== Functions used in this tutorial ========================
  34.  
  35.    cols        Ask the number of columns on a logical window
  36.    getactive   Ask the active logical window
  37.    getlwin     Ask the current logical window
  38.    getcol      Ask the prefered number of columns on a logical window
  39.    getrow      Ask the prefered number of rows on a logical window
  40.    lines       Ask the number of rows on a logical window
  41.  
  42.  
  43. ============================== Introduction ==================================
  44.  
  45. The screen and window of PowerVisor are very customizable.
  46. Interlace, pal, ntsc, vga, even the A2024 monitor, colors, fonts, ... .
  47. All these characteristics and more are customizable. Read this tutorial
  48. for more information about these options.
  49.  
  50.  
  51. ========================== The PowerVisor Screen =============================
  52.  
  53. Normally PowerVisor uses an ²Intuition screen for output.
  54. The default screen has the following characteristics :
  55.  
  56.   - ²2 bitplanes (four colours)
  57.   - ²non interlaced
  58.   - ¹PAL, ¹NTSC, ¹VGA or ¹A2024 depending on your ²preferences settings
  59.     if you use AmigaDOS 2.0.
  60.     If you use AmigaDOS 1.2 or 1.3 PowerVisor will open a screen as big as
  61.     the ²workbench screen would be if it is not interlaced.
  62.   - Size is inherited from the preferences settings. PowerVisor uses
  63.     ¹overscan if you set overscan in preferences (only AmigaDOS 2.0).
  64.   - ¹Colours are inherited from the Workbench.
  65.   - ¹Topaz.font 8 is uses for all text (default).
  66.   - The screen is a ²public screen if you have AmigaDOS 2.0 (with the
  67.     name ¹'PowerVisorScreen').
  68.  
  69. The PowerVisor screen is partitioned in ²logical windows (see the Logical
  70. Windows section of this tutorial file). PowerVisor gives you the option to
  71. open its window on ²another screen, to change the colours, switch to
  72. interlace, switch to another monitor (2.0) or to use more bitplanes.
  73.  
  74. Note that in this tutorial we constantly talk about three different things :
  75.  
  76.    - The ²PowerVisor screen : This is the Intuition screen. It is possible
  77.      that this screen does not exist. In that case, PowerVisor resides
  78.      on another screen.
  79.    - The ²PowerVisor window : This is the Intuition window that normally
  80.      lives on the screen. When we talk about the PowerVisor window we
  81.      are talking about the physical window 'Main'. PowerVisor can have
  82.      more physical windows.
  83.    - ²Physical windows : These correspond directly with Intuition windows.
  84.    - ²Logical Windows : Each physical window is partitioned in logical
  85.      windows, do not confuse a logical window with an Intuition window.
  86.  
  87.  
  88. ========================== Reading this chapter ==============================
  89.  
  90. All the examples in this chapter assume that you have an ²NTSC monitor.
  91. If this is not the case replace 'NTSC' with 'PAL' and 'PAL' with 'NTSC'
  92. (in your mind) when you read this chapter. I also assume that you have
  93. started a vanilla PowerVisor. This means that there was no
  94. ¹s:PowerVisor-config and a minimal ¹s:PowerVisor-startup when you started
  95. PowerVisor.
  96.  
  97.  
  98. ========================= Interlace and Monitors =============================
  99.  
  100. If the PowerVisor screen is open (default when you start PowerVisor),
  101. you can switch to interlace or to another monitor using the 'mode'
  102. command (This command is also used for other settings, see the
  103. appropriate documentation). The 'mode' command with screen arguments
  104. has no effect when PowerVisor resides on another screen.
  105.  
  106. The following 'mode' arguments have something to do with screens or
  107. windows :
  108.  
  109.    - lace         switch to ¹interlace
  110.    - nolace       switch to ²non interlace (default)
  111.  
  112.    - pal          ²pal monitor (AmigaDOS 2.0)       640x256 or 640x512
  113.    - ntsc         ²ntsc monitor (AmigaDOS 2.0)      640x200 or 640x400
  114.    - vga          ²vga monitor (AmigaDOS 2.0)       640x480 or 640x960
  115.    - viking       ²a2024 monitor (AmigaDOS 2.0)     1024x1008
  116.  
  117.    - fancy        use ²two bitplanes (default)
  118.    - nofancy      use only ²one bitplane
  119.  
  120.    - sbottom      ¹sizegadget is included in ²bottom border (default)
  121.                   this option is only useful if there are more physical
  122.                   windows, or if the 'Main' physical window is a
  123.                   ²non-backdrop window.
  124.    - nosbottom    ¹sizegadget is included in ²right border
  125.  
  126. Here are some examples :
  127.  
  128. < mode lace nofancy <enter>
  129.  
  130. You will now get a one bitplane interlace screen (if you have enough
  131. memory).
  132.  
  133. Note that PowerVisor only uses half the interlaced screen for output
  134. (try some commands with a lot of output to test this: 'help commands',...).
  135. This is normal. We will see later how you can make the logical window
  136. ²full size again (in the Logical Windows section).
  137.  
  138. Back to normal with :
  139.  
  140. < mode fancy nolace <enter>
  141.  
  142.  
  143. =========================== Setting the colours ==============================
  144.  
  145. Try :
  146.  
  147. < color 0 0 0 7 <enter>
  148. < color 1 15 15 15 <enter>
  149.  
  150. This will install a blue background and a white foreground. (Note that
  151. this command only works if PowerVisor is on its own screen (see later for
  152. more info)).
  153.  
  154.  
  155. ======================= PowerVisor on other screen ===========================
  156.  
  157. You can open the ²PowerVisor window on each screen available in the system.
  158. However, when you do this you must be very careful NOT to close the screen
  159. where PowerVisor resides.
  160.  
  161. Example :
  162.  
  163. List all screens :
  164.  
  165. < list scrs <enter>
  166. > Screen name         : Address  Left  Top Width Height FirstWindow
  167. > ---------------------------------------------------------------------------
  168. > PowerVisor   (V1.00/: 07EA28F0    0    0   692    442 07EA67B8
  169. > Workbench Screen    : 07E280D0    0 -582   692   1024 07E1F0F8
  170.  
  171. For example, let's open on the ²Workbench screen :
  172.  
  173. < screen Workbench <enter>
  174.  
  175. You can now change the size of the PowerVisor window :
  176.  
  177. < size main 600 150 <enter>
  178.  
  179. This command sizes the specified ²physical window ('Main' in this case). The
  180. 'size' command only works on ²non-backdrop windows.
  181.  
  182. You can also move the PowerVisor window with :
  183.  
  184. < move main 10 10 <enter>
  185.  
  186. You can also resize the PowerVisor window using the size gadget.
  187. The 'screen' command normally opens a window with the same size as the previous
  188. size. If this is too big for the new screen, PowerVisor will make the window
  189. as big as possible.
  190.  
  191. When PowerVisor is on another screen, you cannot use the following commands :
  192.  
  193.    - color
  194.    - mode with one of the following arguments :
  195.          fancy,nofancy,pal,ntsc,vga,viking,lace,nolace
  196.  
  197. If you are configuring PowerVisor in a special way you can also make the
  198. 'Main' physical window a non-backdrop window on the PowerVisor screen :
  199.  
  200. < screen 0 <enter>
  201.  
  202. Now you can size and move the PowerVisor window.
  203.  
  204. Go back to the PowerVisor intuition screen :
  205.  
  206. < screen <enter>
  207.  
  208. Note that the 'screen' commands moves all physical windows (see later)
  209. present.
  210.  
  211.  
  212. ====================== The PowerVisor window system ==========================
  213.  
  214. The ³³PowerVisor window system is fairly complex. At the hart of the system
  215. you have the ²²physical windows. These correspond directly with
  216. ²Intuition windows. Normally there is only one physical window called 'Main'.
  217. This window also contains the ¹stringgadget. You can open more physical
  218. windows if you want (see later).
  219.  
  220. Each physical window has a ³tree of boxes. A ¹¹box is some space that can
  221. later be used by ²logical windows. By default there is only one box on
  222. a physical window. This box is called the ¹masterbox and is always present
  223. (you can't remove this box). When you open more logical windows on a physical
  224. windows the appropriate boxes are made automatically, so you generally need
  225. not concern yourselves with these objects.
  226.  
  227. A box is not always used by a logical window. Sometimes it is used by two
  228. other boxes. For example: if you want three logical windows, two above
  229. each other and the third one right of the previous two. You now seem to
  230. have three boxes :
  231.  
  232.                   +---------+-------+
  233.                   |         |       |
  234.                   |         |       |
  235.                   |    1    |       |
  236.                   |         |       |
  237.                   |         |       |
  238.                   +---------+   3   |
  239.                   |         |       |
  240.                   |         |       |
  241.                   |    2    |       |
  242.                   |         |       |
  243.                   |         |       |
  244.                   +---------+-------+
  245.  
  246. In this example there are three boxes containing a logical window. But there
  247. are in fact five boxes on the physical window.
  248. First the masterbox :
  249.  
  250.                   +-----------------+
  251.                   |                 |
  252.                   |                 |
  253.                   |                 |
  254.                   |                 |
  255.                   |                 |
  256.                   |        4        |
  257.                   |                 |
  258.                   |                 |
  259.                   |                 |
  260.                   |                 |
  261.                   |                 |
  262.                   +-----------------+
  263.  
  264. The masterbox contains two boxes :
  265.  
  266.                   +---------+-------+
  267.                   |         |       |
  268.                   |         |       |
  269.                   |         |       |
  270.                   |         |       |
  271.                   |         |       |
  272.                   |    5    |   3   |
  273.                   |         |       |
  274.                   |         |       |
  275.                   |         |       |
  276.                   |         |       |
  277.                   |         |       |
  278.                   +---------+-------+
  279.  
  280. Box 5 contains two other boxes and box 3 contains a logical window.
  281.  
  282. It is easy to see the tree structure for the boxes. Box 4 is the masterbox
  283. and only the leaves of the tree contain logical windows.
  284.  
  285.                            +---+
  286.                            | 4 |
  287.                            +---+
  288.                             / \
  289.                            /   \
  290.                           /     \
  291.                        +---+   +---+
  292.                        | 5 |   | 3 |
  293.                        +---+   +---+
  294.                         / \
  295.                        /   \
  296.                       /     \
  297.                    +---+   +---+
  298.                    | 1 |   | 2 |
  299.                    +---+   +---+
  300.  
  301. All boxes containing two other boxes automatically draw a ²²size bar.
  302. By ¹dragging this size bar you can change the size of the two child
  303. boxes. For example, dragging the ³vertical size bar between box 5
  304. and box 3 (thus managed by box 4) changes the size of box 5,3,1 and 2.
  305. Dragging the ³horizontal size bar between box 1 and 2 (managed by
  306. box 5) only changes the size of box 1 and 2. Note that each parent
  307. box remembers the size for the two children with one number: this number
  308. is the percentage (x10) that child A may use of the parent box. This
  309. means that if you change the size of a box, all children are resized
  310. proportionally.
  311.  
  312. When you add a logical window using the appropriate commands (see later),
  313. PowerVisor will add two boxes. For example, if you want to add a logical
  314. window below all boxes already visible, the tree will look as follows
  315. (box 6 and 7 are new) :
  316.  
  317.                            +---+
  318.                            | 6 |
  319.                            +---+
  320.                             / \
  321.                            /   \
  322.                           /     \
  323.                        +---+   +---+
  324.                        | 7 |   | 4 |
  325.                        +---+   +---+
  326.                                 / \
  327.                                /   \
  328.                               /     \
  329.                            +---+   +---+
  330.                            | 5 |   | 3 |
  331.                            +---+   +---+
  332.                             / \
  333.                            /   \
  334.                           /     \
  335.                        +---+   +---+
  336.                        | 1 |   | 2 |
  337.                        +---+   +---+
  338.  
  339. (Note that the masterbox has changed)
  340. The physical window changes to :
  341.  
  342.                   +---------+-------+
  343.                   |         |       |
  344.                   |    1    |       |
  345.                   |         |       |
  346.                   +---------+   3   |
  347.                   |         |       |
  348.                   |    2    |       |
  349.                   |         |       |
  350.                   +---------+-------+
  351.                   |                 |
  352.                   |        7        |
  353.                   |                 |
  354.                   +-----------------+
  355.  
  356.  
  357. A ²²logical window is the object you are probably going to use most. It can
  358. contain text. To know where the text must appear in the ²physical window,
  359. the logical window uses a ¹box. The standard logical window for output is
  360. the ³'Main' logical window. This logical window always resides on the
  361. ³'Main' physical window (but there can be more logical windows on the
  362. 'Main' physical window). There are seven predefined logical windows :
  363.  
  364.    - Main         for normal output
  365.    - Extra        for output
  366.    - Refresh      if present, all output from the 'refresh' command goes to
  367.                   this logical window. Otherwise the output goes to the
  368.                   current logical window
  369.    - Debug        for the fullscreen debugger
  370.    - Rexx         if present, all output from a ¹rexx command goes to this
  371.                   logical window. Otherwise the output goes to the current
  372.                   logical window
  373.    - PPrint       if present, all ¹PortPrint messages go to this logical
  374.                   window. Otherwise the output goes to the current logical
  375.                   window
  376.    - Source       The source logical window used by the sourcelevel debugger
  377.  
  378. You can add your own logical windows.
  379.  
  380. All physical windows currently present can be found in the 'pwin' list.
  381. All logical window can be found in the 'lwin' list.
  382.  
  383.  
  384. ====================== The size of a logical window ==========================
  385.  
  386. A logical window contains text. It has a certain ³number of rows and a
  387. certain ³number of columns. Normally this number is independent of the
  388. ²visible size of the logical window. What this means is that the number of
  389. columns and rows remains the same even if you switch to interlace or if
  390. you change the size of a logical window (by dragging the ²size bar).
  391. This is the reason that PowerVisor only uses half the screen when you
  392. switch from ¹non-interlaced to ¹interlaced. There are several solutions to
  393. this problem :
  394.  
  395. - If you want the number of columns and rows automatically ¹fit for the
  396.   visible size you can make the logical window ¹autoscalable. You can
  397.   do this with the 'colrow' command (see later). The disadvantage of this
  398.   is that the logical window will be cleared everytime the visible size
  399.   changes. If you want you can also make the logical window autoscalable
  400.   for the number of rows only, or for the number of columns only.
  401.  
  402. - If interlace is your default screen type (defined with the 'mode' and
  403.   the 'saveconfig' commands) the 'Main' logical window will be bigger.
  404.   If you switch to non-interlace, the number of columns and rows will
  405.   remain the same. This means that you can scroll in the logical window
  406.   (see later).
  407.  
  408. - You can explicitelly tell PowerVisor to fit the 'Main' logical window
  409.   to the visible size with the 'fit' command (see later). This is not
  410.   the same as the first method since the window will have a ²fixed size
  411.   (not autoscalable).
  412.  
  413. - You can explicitelly set the size of the 'Main' logical window using
  414.   the 'colrow' command. If this size is too big for the visible size,
  415.   you will be able to ¹scroll in the logical window.
  416.  
  417. The first, second and fourth methods can be made permanent with the
  418. 'mode', 'prefs' and 'saveconfig' commands (see the 'Installing
  419. PowerVisor' chapter).
  420.  
  421. Note that this discussion is also valid for other logical windows as well.
  422. All the standard logical windows behave a bit different (you can
  423. change this behaviour with the 'prefs' command) :
  424.  
  425.    - Main      number of columns and rows is set to a fixed value. This value
  426.                is the maximum number of columns and rows at the time the
  427.                logical window is created.
  428.    - Extra     like 'Main'
  429.    - Refresh   the number of columns is set to a fixed value. This value is
  430.                the maximum number of columns at the time the logical window
  431.                is created. The number of rows is fixed and always set to
  432.                50.
  433.    - Debug     the number of columns is fixed and set to 90. The number of
  434.                rows is fixed and set to 42.
  435.    - Rexx      Like 'Refresh'
  436.    - PPrint    Like 'Refresh'
  437.    - Source    Like 'Debug' except that the number of columns and rows
  438.                are autoscalable
  439.  
  440.  
  441. ================= Standard behaviour for logical windows =====================
  442.  
  443. All logical windows can behave different. Here are the possible behaviours
  444. for logical windows :
  445.  
  446.    ¹-MORE- enabled or disabled
  447.                When enabled, PowerVisor will pause when there is a full
  448.                window of output.
  449.    ¹Interrupt/Pause enabled or disabled
  450.                When enabled you can use the <esc> and <right-alt>+<help>
  451.                keys to interrupt or pause PowerVisor when PowerVisor is
  452.                sending output to the logical window.
  453.    ²Home position is top-visible or real-top
  454.                PowerVisor maintains a home position for each logical window.
  455.                This position is either the ²real top of the logical window
  456.                or the first line that is visible (starting from above)
  457.                of the bottom visible half of the logical window.
  458.                When a ³top-visible logical window is cleared, PowerVisor will
  459.                scroll to the bottom part of the logical window and set
  460.                the current cursor position to the first line of this visible
  461.                part.
  462.                When a ³real-top logical window is cleared, PowerVisor will
  463.                scroll to the top part of the logical window and set the
  464.                current cursor position to the first line.
  465.                There is yet another difference between top-visible and
  466.                real-top logical windows. When the visible size of a logical
  467.                window changes (this does not always imply a change of the
  468.                number of rows and columns), PowerVisor will try to keep
  469.                the top visible line (for real-top logical windows) or the
  470.                bottom visible line (for top-visible logical windows) on the
  471.                same visible position.
  472.    ²Status line on/off
  473.                The statusline is the bar at the top of a logical window.
  474.    ³Auto Output Snap on/off
  475.                When enabled, PowerVisor will automatically scroll the logical
  476.                window to the position of the appearing output. This means
  477.                that you will always see all new output on the logical window.
  478.                When disabled, PowerVisor will not scroll and output may
  479.                appear off screen. Note that this flag is only useful when
  480.                the logical window is bigger than the current visible size.
  481.  
  482. The standard logical windows have the following behaviour :
  483.  
  484.    - Main      -MORE- enabled/disabled depending on the setting of
  485.                the 'mode' command (see later)
  486.                Interrupt/Pause enabled
  487.                Home position is top-visible
  488.                Status line on
  489.                Auto Output Snap is on
  490.    - Extra     -MORE- disabled
  491.                Interrupt/Pause enabled
  492.                Home position is top-visible
  493.                Status line on
  494.                Auto Output Snap is on
  495.    - Refresh   -MORE- disabled
  496.                Interrupt/Pause disabled
  497.                Home position is real-top
  498.                Status line on
  499.                Auto Output Snap is off
  500.    - Debug     -MORE- disabled
  501.                Interrupt/Pause disabled
  502.                Home position is real-top
  503.                Status line on
  504.                Auto Output Snap is off
  505.    - Rexx      -MORE- disabled
  506.                Interrupt/Pause disabled
  507.                Home position is top-visible
  508.                Status line on
  509.                Auto Output Snap is off
  510.    - PPrint    -MORE- disabled
  511.                Interrupt/Pause disabled
  512.                Home position is top-visible
  513.                Status line on
  514.                Auto Output Snap is off
  515.    - Source    -MORE- disabled
  516.                Interrupt/Pause disabled
  517.                Home position is real-top
  518.                Status line on
  519.                Auto Output Snap is off
  520.  
  521. All other logical windows have the following default behaviour :
  522.  
  523.    -MORE- disabled
  524.    Interrupt/Pause enabled
  525.    Home position is top-visible
  526.    Status line on
  527.    Auto Output Snap is off
  528.  
  529. You can change the ²default behaviour for the standard logical windows
  530. with the 'prefs' command. You can change the behaviour for each logical
  531. window with the 'setflags' command (see later).
  532.  
  533.  
  534. ==================== Opening standard logical windows ========================
  535.  
  536. There are predefined commands to open the ³standard logical windows :
  537.  
  538.    - xwin   Extra
  539.    - dwin   Debug
  540.    - rwin   Refresh
  541.    - awin   Rexx
  542.    - owin   PPrint
  543.    - swin   Source
  544.  
  545. These commands open/close the specified logical window at the top. This means
  546. that they split the ¹masterbox and add a new box above all other logical
  547. windows. This box gets 30 % of the total physical window height. The logical
  548. windows in the remaining 70 % are shrinked accordingly. These predefined
  549. commands always open the window on the ³'Main' physical window.
  550.  
  551. These commands also have an optional argument to indicate the number of
  552. lines you want in the logical window.
  553.  
  554. If the 'intui' mode flag (set with the 'mode' command) is set, then these
  555. commands will also create a physical window with the same name as the
  556. standard logical window. The logical window is opened in this new
  557. physical window. The optional argument is ignored if this is the case.
  558.  
  559.  
  560. Some examples :
  561.  
  562. < xwin <enter>
  563.  
  564. Now we have two logical windows on our 'Main' physical window. These two
  565. logical windows are called 'Main' and 'Extra'. You can change the size
  566. of the windows by dragging the ²horizontal bar.
  567.  
  568. You can now use this window instead of 'Main' for output :
  569.  
  570. < current extra <enter>
  571.  
  572. Type some command :
  573.  
  574. < list task <enter>
  575. > Task node name      : Node     Pri StackPtr  StackS Stat Command         Acc
  576. > ----------------------------------------------------------------------------
  577. > Background Process  : 07E28330 00  07E2D500    4096 Wait iprefs     (02) -
  578. > PowerSnap 1.0 by Nic: 07E51228 05  07E51A72    2000 Wait            PROC -
  579. > Background Process  : 07E5B3E8 00  07E5AD92    4096 Wait addtools   (06) -
  580. > SYS:System/CLI      : 07E5CAA8 00  07E5D9E6    4096 Wait            (00) -
  581. > * Blanker           : 07E605D8 00  07E615E4    4000 Wait            PROC -
  582. > RexxMaster          : 07E4AD58 04  07E4B59A    2048 Wait            (00) -
  583. > ...
  584.  
  585. The output appears on 'Extra'.
  586.  
  587. < current main <enter>
  588.  
  589. Now all following output will appear on 'Main'.
  590.  
  591. You can also use the 'on' command :
  592.  
  593. < on extra list task <enter>
  594. > Task node name      : Node     Pri StackPtr  StackS Stat Command         Acc
  595. > ----------------------------------------------------------------------------
  596. > Background Process  : 07E28330 00  07E2D500    4096 Wait iprefs     (02) -
  597. > PowerSnap 1.0 by Nic: 07E51228 05  07E51A72    2000 Wait            PROC -
  598. > Background Process  : 07E5B3E8 00  07E5AD92    4096 Wait addtools   (06) -
  599. > SYS:System/CLI      : 07E5CAA8 00  07E5D9E6    4096 Wait            (00) -
  600. > * Blanker           : 07E605D8 00  07E615E4    4000 Wait            PROC -
  601. > RexxMaster          : 07E4AD58 04  07E4B59A    2048 Wait            (00) -
  602. > ...
  603.  
  604. This command temporarily sets the current logical window to the parameter
  605. supplied. It then executes the following command ('list task' in this
  606. example).
  607.  
  608. To see all logical windows you can list them :
  609.  
  610. < list lwin <enter>
  611. > Logical Window      : Node
  612. > ---------------------------------------------------------------------------
  613. > Extra               : 07EBCB20
  614. > Main                : 07E25A60
  615.  
  616. Close 'Extra' with :
  617.  
  618. < xwin <enter>
  619.  
  620.  
  621. =================== Opening logical windows in general =======================
  622.  
  623. Instead of using the predefined commands to open the standard logical windows
  624. you can also use the more powerful 'openlw' and 'closelw' commands. These
  625. commands can also be used to open other logical windows.
  626.  
  627. Some examples :
  628.  
  629. To open the 'Extra' logical window right from the 'Main' logical window
  630. (instead of above the 'Main' logical window) you can use :
  631.  
  632. < openlw main extra 80 40 main r <enter>
  633.  
  634. The first argument is the ²physical window where we want to open the new
  635. ²logical window. The second argument is the name of the logical window.
  636. The two following arguments are the number of columns and rows. If you
  637. want an ³autoscale logical window you can use -1 for one or both of
  638. these arguments. The two last arguments specify where you want to open
  639. the 'Extra' logical window. In this case we opened it at the right ('r')
  640. of the 'Main' logical window.
  641.  
  642. Do not close this logical window yet. We will first open a third :
  643.  
  644. < openlw main testwindow 100 -1 extra u <enter>
  645.  
  646. This window is autoscalable for the height. This means that when you change
  647. the horizontal visible size nothing will happen, but if you change the
  648. visible vertical size the window will be cleared and the number of columns
  649. will change.
  650. Now we have three logical windows on the 'Main' physical window.
  651.  
  652. Suppose we wanted to open a logical window at the bottom of the physical
  653. window. This can be done with :
  654.  
  655. < openlw main bottomwindow 80 40 main pd <enter>
  656.  
  657. The 'pd' argument means that we first take the parent and then go down.
  658. You will probably understand how this works when you think how PowerVisor
  659. manages ²logical windows and ¹boxes. When you said something like 'extra u'
  660. some commands ago, PowerVisor interpreted this as : take the box containing
  661. the 'extra' logical window. Split this box (make a new parent instead of
  662. the old box and make the existing 'extra' box a child of this new parent,
  663. also create a new box as the brother of the 'extra' box) and put the new
  664. logical window above the 'extra' logical window. When you say something like
  665. 'main pd' in the previous command, PowerVisor interpretes this as : take
  666. the box containing the 'main' logical window. Take the parent of this box
  667. (the 'p' stands for parent) and perform the same action as described before
  668. on this parent box.
  669.  
  670. You can use as many p's in front of the direction argument as you wish.
  671. You can use u (up), d (down), r (right) or l (left) for direction
  672. arguments.
  673.  
  674. To close all logical windows use :
  675.  
  676. < closelw extra <enter>
  677. or
  678. < xwin <enter>
  679.  
  680. < closelw testwindow <enter>
  681. < closelw bottomwindow <enter>
  682.  
  683. Now we are back with only one logical window: 'Main'.
  684.  
  685.  
  686. ======================== Opening physical windows ============================
  687.  
  688. You are not limited to the default physical window 'Main'. You can open
  689. five additional ²physical windows (This limitation stems from the fact that
  690. PowerVisor only has 5 remaining signals. In a later release of PowerVisor
  691. this limitation will probably be removed). These physical windows can contain
  692. as many logical windows as memory permits.
  693.  
  694. For example, open a physical windows and two logical windows in it :
  695.  
  696. < openpw test 0 0 400 150 <enter>
  697.  
  698. You now have an extra window on position (0,0), width 400 and height 150.
  699.  
  700. < openlw test leftwin 80 40 <enter>
  701.  
  702. Note that for the first logical window on a physical window you need not
  703. give positional arguments.
  704.  
  705. < openlw test rightwin 80 40 leftwin r <enter>
  706.  
  707. Some tests :
  708.  
  709. < on leftwin list wins <enter>
  710. > ...
  711.  
  712. < on rightwin list scrs <enter>
  713. > ...
  714.  
  715. You need not close the logical windows. If you close the physical window
  716. the logical windows are closed automatically :
  717.  
  718. < closepw test <enter>
  719.  
  720.  
  721. ========================== Active versus current =============================
  722.  
  723. The ³³current logical window is simply the window receiving all output from
  724. the commands you type on the commandline. The default current logical window
  725. is 'Main'. With the 'current' command you can change this permanently or
  726. you can use the 'on' command to execute one command (or more using groups)
  727. on another current logical window.
  728.  
  729. The ³³active logical window is the logical window with the full ²size bar
  730. (blue if you have the standard AmigaDOS 2.0 ¹palette and if you use 2
  731. bitplanes). You can scroll the active logical window (see the next section).
  732. The most important distinction (note that this is new for version V1.10
  733. of PowerVisor) is the fact that input is not directed to the current logical
  734. window but to the active one. For normal commandline mode this makes no
  735. difference because all logical windows will accept the input, execute the
  736. command and send the output to the current logical window. But what happens
  737. if a certain command executing with a certain current logical window asks
  738. for input ? PowerVisor will block all other logical windows and only accept
  739. input if the active logical window is the one waiting for input.
  740.  
  741. An example :
  742.  
  743.    Assume that you are running an ARexx script and you have the 'Rexx'
  744.    logical window open. At some intervals this script sends output to
  745.    the 'Rexx' window. You are simply typing commands and looking at the
  746.    output on the 'Main' logical window (the current logical window).
  747.    Note that when ARexx executes a command, the current logical window
  748.    is temporarily set to 'Rexx'.
  749.  
  750.    The 'Main' logical window is also the active one.
  751.  
  752.    At some moment the ARexx script needs input. At once you will not be able
  753.    to type. The commandline will be locked and the current list indicator
  754.    will have changed to '------'. If you see this you know that some other
  755.    logical window is waiting for input. With the <tab> key you make the
  756.    'Rexx' logical window active. The current list indicator changes
  757.    to '-HALT-' or '????' or some other string depending on the type of input
  758.    the ARexx program wants. The input is unlocked and you can type the input
  759.    needed for the ARexx program.
  760.  
  761.  
  762. In summary the following things are valid for a current logical window :
  763.  
  764.    - all output appears there (note that some commands executed in special
  765.      environments like ARexx have other current logical windows)
  766.    - when a command executing on a certain current logical window wants
  767.      input, all other logical windows are locked (the current list indicator
  768.      changes to '------' if one of these logical windows is active)
  769.  
  770. The following things are valid for an active logical window :
  771.  
  772.    - you can scroll (next section) the active logical window
  773.    - you can interrupt the command (with <esc>) when the active logical
  774.      window is equal to the current logical window for that command
  775.    - you can pause the output (with <right-alt>+<help>) when the active
  776.      logical window is equal to the current logical window for that
  777.      command
  778.    - the active logical window also determines the state of the current
  779.      list indicator and the possibility to use input for that logical window
  780.  
  781.  
  782. The following current list indicators are used in PowerVisor :
  783.  
  784.    -MORE-   the command has just printed a full page of output, press space
  785.             to continue the output (see the 'More...' section later in this
  786.             file)
  787.    -HALT-   you have paused the command with <right-alt>+<help> or the
  788.             command is waiting for a key (with the 'key' function)
  789.    -BUSY-   you can't use input in any logical window, PowerVisor is busy
  790.             with something (executing a command for example)
  791.    ------   the logical window is locked for input. This means that there is
  792.             another logical window waiting for input (cycle with <tab> until
  793.             you find that other logical window)
  794.    ????>    some command is waiting for a full line of input (with the 'scan'
  795.             command)
  796.    Task>    'Task', 'Libs', ... or some other current list simply indicates
  797.             that you are in normal command executing mode. All logical
  798.             window accept input in this mode but output is always directed
  799.             to the current logical window
  800.    ?        something else. This is the same as with '????>' but you can
  801.             change the current list indicator with the 'scan' command
  802.  
  803.  
  804. Note. There is a bug in PowerVisor for AmigaDOS 1.2/1.3. I have not been
  805. able to find a way to unactivate (unselect) a stringgadget. So you will
  806. sometimes have to unselect the gadget yourselves (press enter or click
  807. on the window) before you can press the key. I'm sorry for this.
  808. In AmigaDOS 2.0 everything is fine.
  809.  
  810.  
  811. ====================== Scrolling in logical windows ==========================
  812.  
  813. As was mentioned before, the number of columns and rows in a logical window
  814. can be greater than the visible number of columns and rows. If this is
  815. the case you can ¹¹scroll in the logical window.
  816.  
  817. The window that will scroll when you use the appropriate ¹keys (see below)
  818. is the one that is active (see the previous section).
  819.  
  820. The following keys are defined (numeric keypad) :
  821.  
  822.    - <l-alt>+<home>   (7)  go to the top left position in the logical window
  823.    - <l-alt>+<end>    (1)  go to the bottom left position
  824.    - <l-alt>+<pgup>   (9)  scroll 5 lines up
  825.    - <l-alt>+<pgdn>   (3)  scroll 5 lines down
  826.    - <l-alt>+<arrows> (2,4,6,8)
  827.                            scroll one line/column in the right direction
  828.    - <l-alt>+<cntr>   (5)  go to the complete right
  829.    - <tab>                 make the next logical window active
  830.  
  831.  
  832. To let you experiment with all keys try the following :
  833.  
  834. < colrow main 100 80 <enter>
  835.  
  836. This command sets the number of columns and rows to 100 and 80
  837. resp. Now put some output on the screen (with 'memory' or 'list')
  838. and scroll in all directions.
  839.  
  840. Note that the little box in the statusline changes when you scroll.
  841. This box is an indicator of where you are in the logical window. If you
  842. can't scroll (because the number of columns and rows is less or equal than
  843. the number of columns and rows visible) the box will be full. Otherwise
  844. it represents the position of the visible size of the logical window.
  845.  
  846.  
  847. ============================ Setting the Font ================================
  848.  
  849. You can install a different ²non-proportional font for each logical window.
  850. The ²default font is always ²'topaz 8'.
  851.  
  852. Open the 'Debug' window :
  853.  
  854. < dwin <enter>
  855.  
  856. (Ignore the 'task not loaded' message, you will need this later when you
  857. start debugging).
  858.  
  859. < setfont debug topaz.font 9 <enter>
  860.  
  861. You will see that the size of the letters change.
  862. The fonts you want to use must be either memory resident or available in
  863. the 'fonts:' directory.
  864.  
  865. < setfont main courier.font 13 <enter>
  866.  
  867. (You must have a non-proportional courier.font in your 'fonts:' directory to
  868. do this).
  869.  
  870. To restore everything type :
  871.  
  872. < dwin <enter>
  873. < setfont main topaz.font 8 <enter>
  874.  
  875.  
  876. ============================ The Snap Feature ================================
  877.  
  878. (Also see the 'Snapping Away' section of the 'GettingStarted' tutorial file).
  879.  
  880. If you click anywhere on the PowerVisor window (except on size bars),
  881. PowerVisor will ¹'snap' the word under the mousepointer to
  882. the commandline. If there is no word under the mousepointer nothing
  883. happens.
  884.  
  885. This feature works on all logical windows regardless of their size, font,
  886. number of columns, ...
  887.  
  888. Note that the snap will not happen if the window is just made active.
  889. You must click twice if the window is not active and you want to snap
  890. something.
  891.  
  892. The 'snapping' feature can behave in different ways. You can use the
  893. 'mode' command to set the behaviour you like most.
  894.  
  895.  
  896. ================================= Refresh ====================================
  897.  
  898. The 'Refresh' logical window can be used together with the 'refresh'
  899. command.
  900.  
  901. Open the 'Refresh' window and make the window big enough :
  902.  
  903. < rwin <enter>
  904.  
  905. Start the refresh of the current list :
  906.  
  907. < refresh 10 {home;list} <enter>
  908.  
  909. (See the 'Expressions' tutorial file for more info about the grouping
  910. operator '{}').
  911.  
  912. This 'refresh' command will execute 'home' and 'list' one time
  913. each second and send the output to the 'Refresh' logical window.
  914. Using the 'tab' key and the numeric keypad keys (with left-alt) you
  915. can now scroll in this refresh display.
  916.  
  917. To disable the refresh use :
  918.  
  919. < refresh 0 <enter>
  920.  
  921. and close 'Refresh' with :
  922.  
  923. < rwin <enter>
  924.  
  925.  
  926. =============================== Redirection ==================================
  927.  
  928. If you want to ³redirect all output of a logical window to a file you can
  929. use :
  930.  
  931. < log main file <enter>
  932.  
  933. Now all output that appears on 'Main' is also sent to the file 'file'.
  934.  
  935. You can stop the redirection with :
  936.  
  937. < log <enter>
  938.  
  939. or 'log' with another logical window, since there can only be one log
  940. file active at the same time.
  941.  
  942. If you are ²logging output to a file it can be useful to have no output on
  943. the PowerVisor screen. You can accomplish this with :
  944.  
  945. < -list <enter>
  946.  
  947. When you precede a line with '-', PowerVisor will send the output from the
  948. following command to void. Except when you have logging enabled.
  949.  
  950. If you want to temporarily discard the ¹feedback (the reprint of the
  951. executed command on the screen) you can type :
  952.  
  953. < ~list <enter>
  954. > ...
  955.  
  956. This '~' operator is very useful if you want to ³attach a command to a key.
  957. If you precede the command in this attachment with a '~', PowerVisor will
  958. execute the command without showing it on the screen.
  959.  
  960. You can also disable this feedback for all commands you type with :
  961. < mode nofb <enter>
  962.  
  963. To enable it type (this is default) :
  964. < mode fb <enter>
  965.  
  966. If you want to combine these two operators you must use the following order
  967. (See the 'TechnicalInfo' file for more information about commandline
  968. parsing) :
  969.  
  970. < ~-list <enter>
  971.  
  972. If you only want the output from one command in a file you can use the
  973. 'to' command :
  974.  
  975. < to ram:MyOutputFile list task <enter>
  976. > ...
  977.  
  978. The output will still appear on the current logical window. This command
  979. temporarily works like the 'log' command. The real log file is restored
  980. after this command exits.
  981. If you only want output in a file you can use :
  982.  
  983. < -to ram:MyOutputFile list task <enter>
  984.  
  985. or
  986.  
  987. < to ram:MyOutputFile -list task <enter>
  988.  
  989. You can also combine the 'to' and the 'on' command :
  990.  
  991. First open the 'Extra' window (if it is not already open) :
  992. < xwin <enter>
  993.  
  994. < to ram:MyOutputFile on extra list task <enter>
  995. > ...
  996.  
  997. This command will list all tasks on the 'Extra' logical window. No output
  998. will be written to the file since the 'to' command only redirects the output
  999. from the ³current logical window. However :
  1000.  
  1001. < on extra to ram:MyOutputFile list task <enter>
  1002. > ...
  1003.  
  1004. will also list all task on the extra window. The difference is that this
  1005. time there will be output in the file since the 'to' command redirects
  1006. the output from the current logical window. At the time the 'to' command
  1007. is executed, this logical window is equal to 'Extra'.
  1008.  
  1009.  
  1010. ================================== Pens ======================================
  1011.  
  1012. You can change the color pens used for various drawing elements with the
  1013. 'prefs pens' command. See the 'InstallingPowerVisor' tutor file for
  1014. more information.
  1015.  
  1016.  
  1017. ================================ More ... ====================================
  1018.  
  1019. If the output of a specific command is too big, PowerVisor will wait and
  1020. display a ¹prompt. Try this :
  1021.  
  1022. Make the number of columns and rows for 'Main' just big enough :
  1023.  
  1024. < fit main <enter>
  1025.  
  1026. List a lot of memory :
  1027.  
  1028. < memory 0 10000 <enter>
  1029. > 00000000: 00000000  07E007CC  00F80834  00F80B16           ...........4....
  1030. > 00000010: 00F80ADA  00F80ADC  00F80ADE  00F80AE0           ................
  1031. > 00000020: 00F80C00  00F80AE4  00F80AE7  00F80AE8           ................
  1032. > 00000030: 00F80AEA  00F80AEC  00F80AEE  00F80AF0           ................
  1033. > 00000040: 00F80AF2  00F80AF4  00F80AF6  00F80AF8           ................
  1034. > 00000050: 00F80AFA  00F80AFC  00F80AFE  00F80B00           ................
  1035. > 00000060: 00F80B02  00F810F4  00F81152  00F81188           ...........R....
  1036. > 00000070: 00F811E6  00F8127C  00F812C6  00F81310           .......|........
  1037. > 00000080: 00F80B70  00F80B72  00F80B74  00F80B76           ...p...r...t...v
  1038. > 00000090: 00F80B78  00F80B7A  00F80B7C  00F80B7E           ...x...z...|...~
  1039. > 000000A0: 00F80B80  00F80B82  00F80B84  00F80B86           ................
  1040. > ...
  1041.  
  1042. After each page of output PowerVisor will display a prompt. Press any key
  1043. to ³continue the output. Press ¹<esc> ³abort the output.
  1044.  
  1045. < <esc>
  1046. > Break...
  1047.  
  1048. Note that PowerVisor will display this prompt after each page. A ¹page is
  1049. defined as the number of lines in the logical window. All these lines
  1050. do not have to be visible. For example, if the 'Main' logical window
  1051. is bigger than the visible size on screen, PowerVisor will only display
  1052. a prompt after the TOTAL number of lines has passed. You can always
  1053. scroll back to view the rest of the output if you want.
  1054.  
  1055. You can disable this prompt with :
  1056.  
  1057. < mode nomore <enter>
  1058.  
  1059. And enable it with :
  1060.  
  1061. < mode more <enter>
  1062.  
  1063. The 'Main' logical window is the only window with a ²'-MORE-' prompt. All
  1064. the other logical windows simply scroll until you interrupt them in one
  1065. way or another. (Note that you can change this behaviour if you want to
  1066. with the 'prefs' command (see the 'InstallingPowerVisor' file)).
  1067.